<%= render :partial => "shared/admin_links" %>
<%= will_paginate_locale @orders %>
<table class="adminTableOrders" border="0" width="100%" cellpadding="4" cellspacing="0">
  <tr class="adminTableHeader"><th><%= t("site.cms.label.id") %></th><th><%= t("site.cms.label.status") %></th>
    <th><%= "#{t("site.cms.action.show")}/#{t("site.cms.action.edit")}" %></th><th><%= t("site.cms.action.delete") %></th></tr>
  <% @orders.each do |order| %>
    <tr>
      <td><%= order.id %></td>
      <td><%= order.status %></td>
      <td>
        <%= if order.status == 'operator_approved' %>
          <% link_to "#{t("site.cms.action.show")} #{t("site.cms.entity.order")} #{order.id}", show_admin_order_path(:id => order.id) %>
        <% else %>
          <%= link_to "#{t("site.cms.action.edit")} #{t("site.cms.entity.order")} #{order.id}", edit_order_path(:id => order.id) %>
        <% end %>
      </td>
      <td><%= link_to "#{t("site.cms.action.delete")} #{t("site.cms.entity.order")} #{order.id}", order_path(:id => order.id),
          :method => :delete, :confirm => t("site.cms.label.sure") %></td>
    </tr>
  <% end %>
</table>
<%= will_paginate_locale @orders %>
